home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Directorty Opus 5 - Magellan
/
Opus 5 - Magellan.iso
/
Extras
/
Show&Edit_1.8
/
ARexx
/
XSelect.dopus5
< prev
Wrap
Text File
|
1996-11-28
|
1KB
|
68 lines
/* $VER: XSelect.dopus5 1.0 (28.11.96) Frederic Steinfels
*/
/* History:
1.0 First try
1.1 If you selected some files in icon mode, dopus also took
the files in name mode. Now, dopus deselects all files
in name mode first if you are in icon mode.
*/
options failat 21
options results
parse arg arguments
Call Init
address value PORT
Call XSelect
Return
XSelect:
lister query handle mode
if UPPER(result) ~= 'NAME' then do
drop result
lister query handle numselentries
numsel=result
do while numsel > 0
lister query handle firstsel
lister select handle result off
numsel=numsel-1
end
end
cnt=0
do while cnt < FILES.count
lister select handle '"' || FILES.cnt || '"' ON
cnt=cnt+1
end
return
Init:
libname = "rexxdossupport.library"
if ~show("L", libname) then do
if ~addlib(libname, 0, -30, 2) then do
say libname "not added!"
exit
end
end
ProgramName = "XSelect.rexx"
ArgsTemplate = "PORT/A,HANDLE/A,FILES/M"
lf='0a'x
if strip(arguments) = '?' then do
call writech(STDOUT, ArgsTemplate || ': ')
pull arguments
end; else nop
if ~ReadArgs(arguments,ArgsTemplate) then do
say Fault(RC,ProgramName)
exit 10
end; else nop
drop arguments
return